<template>
  <el-breadcrumb separator="/">
    <template v-for="item in breads">
      <el-breadcrumb-item
        :key="item.label"
        v-if="item.to"
        :to="{ name: item.to }"
        >{{ item.label }}</el-breadcrumb-item
      >
      <el-breadcrumb-item :key="item.label" v-else>{{
        item.label
      }}</el-breadcrumb-item>
    </template>
  </el-breadcrumb>
</template>

<script>
export default {
  props: ["breads"],
};
</script>
<style></style>
